package com.eckey.lab.service.impl;

import com.alibaba.fastjson.JSON;
import com.eckey.lab.dao.OrderDao;
import com.eckey.lab.entity.Order;
import com.eckey.lab.service.OrderService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Slf4j
@Service
public class OrderServiceImpl implements OrderService {

    @Resource
    private OrderDao orderDao;

    @Override
    public List<Order> lists() {
        List<Order> lists = orderDao.lists();
        log.info("查询订单结果为：{}", JSON.toJSONString(lists));
        return lists;
    }
}
